package me.lc.superDown.sprite.platforms;

import com.wiyun.engine.nodes.Sprite;

import me.lc.superDown.core.GameManager;
import me.lc.superDown.core.GameSystem;
import me.lc.superDown.sprite.Platform;
import me.lc.superDown.util.AudioHelper;

public class SpeedDownPlatform extends Platform {

	@Override
	protected void createPlatformSprite() {
		sp = Sprite.make(GameSystem.tex_platformSpeedDown);
	}

	@Override
	public float getPlatformWidth() {
		return GameSystem.tex_platformSpeedDown.getWidth();
	}

	@Override
	public void standPlatform() {
		// 减速
		GameManager.instance.speedBonus = 0.7f;
	}

	@Override
	public void leavePlatform() {
		// 还原速度
		setManLeaved(true);
		GameManager.instance.speedBonus = 1;
	}
}
